import { $Http } from '@/config/service/http';

export enum Api {
  destroyAuidt = '/dms/archivesFileDestroy/audit', // 审核
  destroyAuthen = '/dms/archivesFileDestroy/authenticate', // 鉴定
  destroyAutoProduct = '/dms/archivesFileDestroy/autoProductFormInfo', // 自动生成表单
  destroyColse = '/dms/archivesFileDestroy/closeFlow', // 关闭流程
  destroyConfirm = '/dms/archivesFileDestroy/confirm', // 确认
  destroyDelete = '/dms/archivesFileDestroy/delete', // 删除
  destroyFindFile = '/dms/archivesFileDestroy/findFileListByFileName', // 通过文件名称模糊查询文件
  destroyGet = '/dms/archivesFileDestroy/get', // 详情
  destroyGetDestroyFiles = '/dms/archivesFileDestroy/getDestroyFiles', // 获取销毁文件列表
  destroyPage = '/dms/archivesFileDestroy/page', // 分页查询
  destroyRevoke = '/dms/archivesFileDestroy/revoke', // 撤回
  destroySave = '/dms/archivesFileDestroy/save' // 保存
}

export const destroyAuidt = (params) => {
  return $Http.api(Api.destroyAuidt, params, 'post');
};

export const destroyAuthen = (params) => {
  return $Http.api(Api.destroyAuthen, params, 'post');
};

export const destroyAutoProduct = (params) => {
  return $Http.api(Api.destroyAutoProduct, params, 'post');
};

export const destroyConfirm = (params) => {
  return $Http.api(Api.destroyConfirm, params, 'post');
};

export const destroyFindFile = (params) => {
  return $Http.api(Api.destroyFindFile, params, 'post');
};

export const destroyGet = (id) => {
  return $Http.api(Api.destroyGet + '/' + id, null, 'get');
};

export const destroyGetDestroyFiles = (params) => {
  return $Http.api(Api.destroyGetDestroyFiles, params, 'post');
};

export const destroySave = (params) => {
  return $Http.api(Api.destroySave, params, 'post');
};
